import { Evaluator } from "./evaluator.js";
import { parse } from "./SyntaxParser.js";

document.getElementById("run").addEventListener('click',event => {
    let tree = parse(document.getElementById('source').value);
    console.log(JSON.stringify(tree, null, '  '))

    let r = new Evaluator().evaluate(tree);
    console.log(r);
});